package com.website.at.online.blogic;

import com.website.at.fw.blogic.IBussiness;
import com.website.at.fw.dao.IQueryDao;
import com.website.at.online.bean.WelcomeForGuestIn;
import com.website.at.online.bean.WelcomeForGuestOut;
import com.website.at.online.entity.CompanyInfo;

/**
 * 
 * @author kongld
 *
 */
public class WelcomeForGuestBlogic implements IBussiness<WelcomeForGuestIn, WelcomeForGuestOut> {

	private IQueryDao queryDao = null;
	
	private static final String SQL_ID_selectForGuestInit = "CompanyInfo.selectForGuestInit";
	@Override
	public WelcomeForGuestOut execute(WelcomeForGuestIn param) {
		CompanyInfo companyInfo = queryDao.executeForObject(SQL_ID_selectForGuestInit, null, CompanyInfo.class);
		
		WelcomeForGuestOut out = new WelcomeForGuestOut();
		if (companyInfo != null) {
			out.setCompanyInfo(companyInfo);
		} else {
			return null;
		}
		return out; 
	}

	/**
	 * @param queryDao the queryDao to set
	 */
	public void setQueryDao(IQueryDao queryDao) {
		this.queryDao = queryDao;
	}
}
